<?php

/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| This file is where you may define all of the routes that are handled
| by your application. Just tell Laravel the URIs it should respond
| to using a Closure or controller method. Build something great!
|
*/

Route::any('test', ['uses' => 'AttachController@test']);    //

/** 角色相关start */
Route::any('role/login', 'PassportController@login');                                                                   // 登录
Route::any('role/logout', 'PassportController@logout');                                                                 // 退出
Route::any('role/getAdminInfo', 'PassportController@getInfo');                                                          // 获取登录信息
Route::any('getConfig', 'PassportController@getConfig');                                                                // 获取网站登录页信息
/** 角色登录end */

//Route::any('image/ueditor', 'UploadCaontroller@ueditor');                                                                // ueditor编辑器配置
Route::any('image/upload', 'UploadController@uploadImage');                                                             // 图片上传
Route::any('image/getHistoryList', 'UploadController@getAll');                                                          // 获取历史上传图片列表
Route::any('image/delHistory', 'UploadController@softDelete');                                                          // 软删除图片
Route::any('image/delete', 'UploadController@delete');                                                                  // 删除图片
//Route::any('file/upload', 'UploadController@upFile');                                                                   // 文件上传

/** 账户管理 */
Route::any('manager/getInfo', 'ManagerController@getInfo');                                                             // 管理员基本信息
Route::any('manager/getAccountPageList', 'ManagerController@getAccountList');                                           // 账户列表
Route::any('manager/doUpdate', 'ManagerController@doUpdate');                                                           // 更新账户信息
Route::any('manager/doAdd', 'ManagerController@doAdd');                                                                 // 添加账户
Route::any('manager/doModifyPwd', 'ManagerController@doModifyPwd');                                                     // 修改密码
Route::any('manager/doDelete', 'ManagerController@doDelete');                                                           // 删除账户
Route::any('manager/doModifyMobile', 'ManagerController@doModifyMobile');                                               // 修改手机号
Route::any('manager/getAll', 'ManagerController@getAll');                                                               // 所有管理员

/** 设置 */
Route::any('setting/getInfo', 'SettingController@getSettingInfo');                                                      // 获取设置
Route::any('setting/toSaveInfo', 'SettingController@toSaveSettingInfo');                                                // 保存设置

/** 商城管理 */
Route::any('mall/getPageList', 'MallController@getPageList');                                                           // 商城列表
Route::any('mall/toAdd', 'MallController@toAdd');                                                                       // 添加商城
Route::any('mall/getInfo', 'MallController@getInfo');                                                                   // 获取商城信息
Route::any('mall/toUpdate', 'MallController@toUpdate');                                                                 // 更新商城
Route::any('mall/toRecycle', 'MallController@toRecycle');                                                               // 回收商城
Route::any('mall/toDelete', 'MallController@toDelete');                                                                 // 删除商城
Route::any('mall/toDisable', 'MallController@toDisable');                                                               // 禁用商城
Route::any('mall/toMigrate', 'MallController@toMigrate');                                                               // 迁移商城

Route::any('sendCode', ['uses' => 'AttachController@sendCode']);                                                                    // 发送验证码


Route::any('initialize/accountData', 'WeController@initializeData');                                                    // 自动交付生成数据
Route::any('initialize/login', 'WeController@toLogin');                                                                 // 登录
Route::any('initialize/modifyTime', 'WeController@toModifyTime');                                                       // 修改到期时间
Route::any('initialize/update', 'WeController@updateInfo');
Route::any('initialize/getInfo', 'WeController@getInfo');


Route::any('cus/openAllAuth','PermissionController@openAllAuth');                                         // 开启所有权限功能
Route::any('cus/functionList','PermissionController@cusFunction');                                         //权限功能列表
Route::any('cus/functionInfo/{id}','PermissionController@cusFunctionInfo');                                //权限功能详情
Route::any('cus/updateFunction','PermissionController@updateFunction');                                    //修改权限功能
Route::any('cus/delFunction/{id}','PermissionController@delFunction');                                     //修改权限功能
Route::any('cus/switchFunction','PermissionController@switchFunction');                                    //开关权限功能
Route::any('cus/updateMode','PermissionController@updateMode');                                            //修改导航栏状态

Route::any('configs/index', 'AttachController@index');